#include "TCP_socket.hpp"

using namespace mycode;

int main(int argc, char *argv[])
{
    //./server ip port
    if (argc != 3)
    {
        std::cout << "server ip port" << std::endl;
        exit(USEERR);
    }
    string ip = argv[1];
    uint16_t port = static_cast<uint16_t>(atoi(argv[2]));

    // 创建TCP对象
    TCP server(ip, port);

    server.server_init();
    server.server_start();

    return 0;
}